package com.kws.system.api;

import com.kws.common.core.constant.ServiceNameConstants;
import com.kws.common.core.domain.R;
import com.kws.system.api.domain.*;
import com.kws.system.api.domain.EQBTemplateVo;
import com.kws.system.api.domain.Express100Info;
import com.kws.system.api.domain.ResultDto;
import com.kws.system.api.domain.Rq.QueryExpress100Rq;
import com.kws.system.api.domain.Rq.UserDto;
import io.swagger.annotations.ApiOperation;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.http.MediaType;
import org.springframework.web.bind.annotation.*;
import org.springframework.web.multipart.MultipartFile;

/**
 * @author : zhangbenting
 * @date : 2024/11/25 16:12
 * @Version: 1.0
 */
@FeignClient(contextId = "RemoteToolService", value = ServiceNameConstants.TOOL_SERVICE)
public interface RemoteToolService {

    @ApiOperation("实名认证")
    @PostMapping("/user/eVerify")
    public R<ResultDto> eVerify(@RequestBody UserDto userDto);

    @ApiOperation("查询物流消息")
    @PostMapping("/query/expressDelivery/page")
    public R<Express100Info> queryExpressDeliveryPage(@RequestBody QueryExpress100Rq rq);

    @ApiOperation("光伏测算")
    @PostMapping("/ToolManage/photovoltaicCalculation")
    R<PhotovoltaicVo> photovoltaicCalculation(@RequestBody PhotovoltaicDto photovoltaicDto);

    @ApiOperation("上传模板")
    @PostMapping(value = "/contract/saveContract", consumes = MediaType.MULTIPART_FORM_DATA_VALUE)
    R<EQBTemplateVo> saveContract(@RequestPart(value = "file") MultipartFile file);


    @ApiOperation("删除模板")
    @PostMapping("/contract/deleteContract/{docTemplateId}")
    R deleteContract(@PathVariable("docTemplateId") String docTemplateId);

    @ApiOperation("根据模板id查询模板控件")
    @GetMapping("/contract/getComponentsInfo/{docTemplateId}")
    R<ResultDto> getComponentsInfo(@PathVariable("docTemplateId") String docTemplateId);

    @ApiOperation("填充模板内容")
    @PostMapping("/contract/createByDocTemplate")
    R<ResultDto> createByDocTemplate(@RequestBody CreateTemplate createTemplate);


    @ApiOperation("创建合同并发起")
    @PostMapping("/contract/createContract")
    R<ResultDto> createContract(@RequestBody CreateContractDto createContractPo);

    @ApiOperation("查看合同--免登录，任何人可查看")
    @GetMapping("/contract/signViewLink/{signFlowId}")
    R<ResultDto> signViewLink(@PathVariable("signFlowId") String signFlowId);

    @ApiOperation("获取签署链接")
    @PostMapping("/contract/signLink")
    R<ResultDto> signLink(@RequestBody QuerySignUrlRq querySignUrlRq);

    @ApiOperation("文件下载地址")
    @GetMapping("/contract/fileDownloadUrl/{signFlowId}")
    R<ResultDto> fileDownloadUrl(@PathVariable("signFlowId") String signFlowId);

    @ApiOperation("查询签署流程详情")
    @GetMapping("/signFlowDetail/{signFlowId}")
    R<ResultDto> signFlowDetail(@PathVariable("signFlowId") String signFlowId);


    @ApiOperation("查询签署流程列表")
    @PostMapping("/contract/signFlowList")
    R<ResultDto> signFlowList(@RequestBody SignFlowRq signFlowRq);

    @ApiOperation("撤销签署流程")
    @PostMapping("/contract/signFlowRevoke")
    R<ResultDto> signFlowRevoke(@RequestBody SignFlowRevoke signFlowRevoke);
//    @ApiOperation("储能测算")
//    @PostMapping("/energyStorageCalculation")
//    R<EnergyStorageVo> energyStorageCalculation(@RequestBody EnergyStorageDto energyStorageDto);
//
//    @ApiOperation("充电桩测算")
//    @PostMapping("/electricPileCalculation")
//    R<ElectricPileVo> electricPileCalculation(@RequestBody ElectricPileDto electricPileDto);
//
//    @ApiOperation("风电测算")
//    @PostMapping("/windPowerCalculation")
//    R<WindPowerVo> windPowerCalculation(@RequestBody WindPowerDto windPowerDto);
//
//    @ApiOperation("微网测算(光储一体化)")
//    @PostMapping("/lightStorageMicroNetwork")
//    R<LightStorageMicroNetworkVo> LightStorageMicroNetwork(@RequestBody LightStorageMicroNetworkDto lightStorageMicroNetworkDto);
//
//    @ApiOperation("微网测算(光储充一体化)")
//    @PostMapping("/lightStorageCharging")
//    R<LightStorageChargingVo> lightStorageCharging(@RequestBody LightStorageChargingDto lightStorageChargingDto);
//
}
